package com.example.officialdocumentsys.controller;


import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.example.officialdocumentsys.annotation.LogAnno;
import com.example.officialdocumentsys.common.R;
import com.example.officialdocumentsys.po.Log;
import com.example.officialdocumentsys.service.LogService;
import com.example.officialdocumentsys.vo.FileVO;
import com.example.officialdocumentsys.vo.LogVO;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;

import org.springframework.web.bind.annotation.RestController;

/**
 * <p>
 * 日志 前端控制器
 * </p>
 *
 * @author hi
 * @since 2022-11-24
 */
@RestController
@RequestMapping("/log")
public class LogController extends BaseController<Log, LogService>{

    //分页
    @LogAnno(operateType = "浏览日志")
    @GetMapping("/page")
    public R<Page> list(int page, int pageSize, String name) {
        Page<LogVO> pageInfo = new Page(page, pageSize);
        LambdaQueryWrapper<LogVO> qw = new LambdaQueryWrapper<>();
        return R.success(baseService.getVO(pageInfo,qw));
    }

}

